<html lang="en">

<head>
    <link rel="stylesheet" href="//at.alicdn.com/t/c/font_2812179_v5ub0sq64aa.css">
    <style type="text/css" id="AMap_Dynamic_style">
        * {
            font-family: simsun, DejaVu Sans, sans-serif;
            font-weight: bold;
        }


        th,
        td {
            border: 2px solid #000 !important;
            /* 每个单元格都有边框 */
            /* padding: 8px; */
            text-align: center;
        }

        th {
            background-color: #f2f2f2;
            /* 设置表头背景色 */
        }

        .main {
            width: 100%;
            margin: 20px auto;
            font-weight: bold;
        }
    </style>
    <meta charset="utf-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width,initial-scale=1.0">
    <link rel="icon" href="/favicon.ico">
    <link rel="stylesheet" href="//at.alicdn.com/t/c/font_2812179_v5ub0sq64aa.css">
    <title>智慧建筑一体化管理平台</title>
</head>

<body class="bg-white">
    <div id="app">
        <div class="main">
            <table cellpadding="10" cellspacing="0" style="width: 790px; border-collapse: collapse; border: none;text-align: center;margin:0 auto;">
                <tr>
                    <td>
                        <div>{$data['serialNumber']}</div>
                        <div>{$data['title']}</div>
                    </td>
                    <td>
                        <div>{$data['subtitle']}</div>
                        <div>{$data['name']}</div>
                    </td>
                </tr>
            </table>

            <table cellpadding="10" cellspacing="0" style="width: 800px; border-collapse: collapse; border: none;margin:0 auto;margin-top: 5px;">
                <tr>
                    <td colspan="4">
                        <div>{$data['noSubtitle']}:</div>
                        <div>{$data['noName']}:</div>
                    </td>
                    <td >
                        <div>{$data['machineSn']}</div>
                    </td>
                    <td colspan="4">
                        <div>Owner:</div>
                        <div>擁有人:</div>
                    </td>
                    <td>
                        <div>{$data['owner']}</div>
                    </td>
                </tr>
                <tr>
                    <td colspan="3" rowspan="2">
                        <div>Date of inspection</div>
                        <div>檢查日期</div>
                    </td>
                    {volist name="data.weekdays" id="item"}
                        <td>
                            <div>{$item['weekday']}</div>
                            <div>{$item['weekdayText']}</div>
                        </td>
                    {/volist}
                </tr>
                <tr>
                    {volist name="data.weekdays" id="item"}
                        {if $item['isSubmited']} 
                            <td>√</td>
                        {elseif(!$item['isSubmited']) /}
                            <td>X</td>
                        {else/}
                            <td></td>
                        {/if}
                    {/volist}
                </tr>
                <tr style="background-color: #f5f0f0;">
                    <td colspan="10" style="text-align: center;">
                        <div>Critical ltems to be checked Daily</div>
                        <div>每日必要检查的项目</div>
                    </td>
                </tr>
                {volist name="data.dayFormData" id="item1" key="index"}
                <tr>
                <td colspan="3" style="text-align: left;">
                    <div>{$index}.{$item1['subtitle']}</div>
                    <div>{$item1['label']}</div>
                </td>
                {volist name="data.weekdays" id="item2"}
                        {if !empty($item2['formData'])} 
                            <?php $isMatch = false; ?>
                            {volist name="item2.formData" id="item3"}
                                {if $item3['renderKey'] == $item1['renderKey']} 
                                    <?php $isMatch = true; ?>
                                    {if $item3['tag'] == 'el-switch' && $item3['defaultValue']} 
                                        <td>√</td>
                                    {elseif($item3['tag'] == 'el-switch' && !$item3['defaultValue']) /}
                                        <td>X</td>
                                    {elseif($item3['tag'] == 'el-input') /}
                                        <td>{$item3['defaultValue']}</td>
                                    {elseif($item3['tag'] == 'signature') /}
                                        <td><img data-v-4324c015=""
                                            src="{$item3['defaultValue']}"
                                            alt="" width="100%"></td>
                                    {else/}
                                    <td></td>
                                    {/if}
                                {/if}
                            {/volist}
                            {if empty($isMatch)} <td></td> {/if}
                        {else/}
                            <td></td>
                        {/if}
                {/volist}
                {/volist}
                </tr>
            </table>

            <table cellpadding="10" cellspacing="0" style="width: 790px; border-collapse: collapse; border: none;margin:0 auto;margin-top: 5px">
                <tr style="background-color: #f5f0f0;">
                    <td colspan="12" style="text-align: center;">
                        <div>General ltems to be checked Weekly (Start on day one)</div>
                        <div>每週一般檢查的項目(由工作的第一天開始)</div>
                    </td>
                </tr>
                {volist name="data.weekFormData[0]" id="item" key="index"}
                    {if ($index-1) % 2 == 0}
                    <tr>
                    {/if}
                    <td colspan="4">
                        <div>{$item['label']}:</div>
                        <div> {$item['subtitle']}:</div>
                    </td>
                    {if $item['tag'] == 'el-switch' && $item['defaultValue']} 
                        <td colspan="2">√</td>
                    {elseif($item['tag'] == 'el-switch' && !$item['defaultValue']) /}
                        <td colspan="2">X</td>
                    {else/}
                        <td colspan="2">$item['defaultValue']</td>
                    {/if}
                    {if $index % 2 == 0}
                    </tr>
                    {/if}
                {/volist}
                <tr>
                    {volist name="data.weekFormData[1]" id="item" key="index"}
                        <td colspan="2" style="width: 16.66%;">
                            <div>{$item['label']}:</div>
                            <div> {$item['subtitle']}:</div>
                        </td>
                        {if $item['tag'] == 'el-input'} 
                            <td colspan="2" style="width: 16.66%;">{$item['defaultValue']}</td>
                        {elseif($item['tag'] == 'signature') /}
                            <td colspan="2" style="width: 16.66%;"><img data-v-4324c015=""
                                src="{$item['defaultValue']}"
                                alt="" width="100%"></td>
                        {elseif($item['tag'] == 'el-date-picker') /}
                            <td colspan="2" style="width: 16.66%;">{$item['defaultValue']}</td>
                        {else/}
                            <td colspan="2" style="width: 16.66%;">{$item['defaultValue']}</td>
                        {/if}
                    {/volist}
                </tr>
            </table>

            <table cellpadding="10" cellspacing="0" style="width: 790px; border-collapse: collapse; border: none;margin:0 auto;margin-top: 5px;">
                <tr>
                    <td style="text-align: center;">
                        <div>The equipment shall not be operated if a defect is noted until authorized by the site supervisor</div>
                        <div>所有機械如發現任何故障，應立即停止使用·直至地盤監工授權為止·</div>
                    </td>
                </tr>
            </table>

            <table cellpadding="10" cellspacing="0" style="width: 790px; border-collapse: collapse; border: none;margin:0 auto;margin-top: 5px;">
                <tr>
                    <td style="text-align: center;">
                        <div>Remark</div>
                        <div>備註</div>
                    </td>
                    <td style="text-align: center;">
                        <div>√-Checkedwithgoodcondition已檢查及狀沉良好</div>
                        <div>x-Checked but not in good condition and need repair已檢查及须要維修</div>
                        <div>N/A-Not Applicable不適用</div>
                    </td>
                </tr>
            </table>

            <table cellpadding="10" cellspacing="0" style="width: 790px; border-collapse: collapse; border: none;margin:0 auto;margin-top: 5px;">
                <tr>
                    <td style="text-align: center;">
                        <div>Verity by Foreman atthe end of week</div>
                        <div>每週完結時由管工核實：</div>
                    </td>

                    {volist name="data.auditFormData" id="item" key="index"}
                        <td style="text-align: center;">
                            <div>{$item['label']}:</div>
                            <div>{$item['subtitle']}：</div>
                        </td>
                        {if $item['tag'] == 'el-input'} 
                            <td style="width: 16.66%;">{$item['defaultValue']}</td>
                        {elseif($item['tag'] == 'signature') /}
                            <td style="width: 16.66%;"><img data-v-4324c015=""
                                src="{$item['defaultValue']}"
                                alt="" width="100%"></td>
                        {elseif($item['tag'] == 'el-date-picker') /}
                            <td style="width: 16.66%;">{$item['defaultValue']}</td>
                        {else/}
                            <td style="width: 16.66%;">{$item['defaultValue']}</td>
                        {/if}
                    {/volist}
                </tr>
            </table>


        </div>
    </div>
    <!-- built files will be auto injected -->
</body>

</html>